function [RM_Structure] = Pull_Out_RM_Single_Session(Data_Summary, Row_Number)

% pull out the RM values first (with the appropriate rotation angle)
RM = Data_Summary(Row_Number).Rate_Map_Corr;
RM_rotation = Data_Summary(Row_Number).RateMap_Corr_Coherent_Rot;
rotation_index = (RM_rotation/90)+1;
RM_values = RM(:,rotation_index);
RM_values(:,2) = RM_values;
for n = 1:size(RM_values, 1)
    RM_values(n,1) = n;
end
for n = 1:size(RM_values,1)
    if isnan(RM_values(n,2))
        RM_values(n,:) = nan;
    end
end
RM_values(isnan(RM_values)) = [];
RM_values = reshape(RM_values, [], 2);

% make a structure that summarizes useful experimental conditions
RM_Structure_Original = struct(...
    'session', Row_Number,...
    'cell_ID', [],...
    'genotype', Data_Summary(Row_Number).genotype,...
    'animal_ID', Data_Summary(Row_Number).animalName,...
    'expt_date', Data_Summary(Row_Number).dateToFind,...
    'drug', Data_Summary(Row_Number).drug,...
    'session1_dose', Data_Summary(Row_Number).session1_dose,...
    'session2_dose', Data_Summary(Row_Number).session2_dose,...
    'exptParadigm', Data_Summary(Row_Number).exptParadigm,...
    'session1_mobility_pass', Data_Summary(Row_Number).Mobility_Session1_Pass,...
    'session2_mobility_pass', Data_Summary(Row_Number).Mobility_Session2_Pass);
RM_Structure = RM_Structure_Original;

% duplicate this structure for N times, where N is the number of non-NAN RM correlation values in
% that session
for n = 1:(size(RM_values,1)-1)
    RM_Structure = cat(1, RM_Structure, RM_Structure_Original);
end

% Now put all RM values into that structure
for n = 1:size(RM_Structure,1)
    RM_Structure(n).cell_ID = RM_values(n,1);
    RM_Structure(n).RM_values = RM_values(n,2);
end


end